<!DOCTYPE html>
<html>
<head lang="en">
    <meta charset="UTF-8">
    <title></title>
    <script src="http://open.web.meitu.com/sources/xiuxiu.js" type="text/javascript"></script>
    <script type="text/javascript">
        function initMeitu(){

            xiuxiu.embedSWF("altContent",5,"630px","440px");
            /*第1个参数是加载编辑器div容器，第2个参数是编辑器类型，第3个参数是div容器宽，第4个参数是div容器高*/
            xiuxiu.setUploadURL("{:C('SITE_URL')}{:U('Shop/Avatar/upload')}");//修改为上传接收图片程序地址
            xiuxiu.setUploadType(2);
            xiuxiu.setUploadDataFieldName("image");
            xiuxiu.onInit = function ()
            {
                xiuxiu.loadPhoto("{:C('SITE_URL')}__PUBLIC__/Shop/img/head.jpg");//修改为要处理的图片url
            }
            xiuxiu.onUploadResponse = function (data)
            {
                console.log(data);
            }
        }
    </script>
</head>

</head>
<body>
<a href="javascript:void();" onclick="initMeitu();">上传头像</a>
<div id="altContent">
    <h1>美图秀秀</h1>
</div>
</body>
</html>